<?php
#Template for plan payment. 
$page = (isset($page)) ? $page : 'free_payment';
include "inc/local_data.php";
$form = (isset($using_real_env) && $using_real_env) ? $form : ((isset($data[$page])) ? $data[$page] : array());
if (empty($form)) exit;

?>
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    <head>
        <title><?php echo $form['title'];?></title>
		<?php include('inc/embed_top.php');?>
    </head>
    <body mlang="<?php echo $form['langs'];?>">
        <div id="pay" class="<?php echo $form['lang'];?> pay" data-role="page" data-theme="f">
            <div class="ptit"><?php echo $form['payment_title'];?><span class="cancel"><a href="<?php echo $form['button']['cancel']['link'];?>" rel="external"><?php echo $form['button']['cancel']['value'];?></a></span></div>
            <?php include('inc/inc.step.php');?>
            <form id="agreeForm" action="<?php echo $form['action'];?>" msgbox_url="<?php echo $form['msgbox_url'];?>" restart_url="<?php echo $form['restart_url'];?>" ajax="<?php echo $form['ajax_url'];?>" method="<?php echo $form['method'];?>" >
				<?php
					foreach($form['hiddens'] as $name=>$item) {
						echo '<input type="hidden" name="'.$name.'" value="'.$item.'" />';
					}
				?>
				<div class="agree">
                    <h2><?php echo $form['payment_info']['agreement'];?></h2>
                    <label for="s-agree" class="no-corner"><input type="checkbox" name="agree_term" id="s-agree" value="1" /><?php echo $form['payment_info']['agree_c'];?></label>
                    <a class="t ui-icon ui-icon-arrow-r" href="<?php echo $form['agree_ment_url'];?>" rel="external" target="_blank">&nbsp;</a>
	    		</div>
	    		<div class="chkcode field">
                    <div class="hd"><label><?php echo $form['payment_info']['captcha'];?></label></div>
                    <div class="ft"><input type="text" class="no-corner intel-text" data-theme="f" name="captcha" value="" title="<?php echo $form['payment_info']['captcha_note'];?>" /></div>
		    	</div>
    			<div class="captcha">
                    <img id="captcha-img" width="200" height="50" src="./image.php?r=<?php echo $microtime;?>" />
    				<a href="javascript:void(0);" rel="external" id="reload-captcha-img">&nbsp;</a>
    			</div>
				<div class="cbtn ui-ubtn grid" data-inline="true">
                    <a href="<?php echo $form['button']['previous']['link'];?>" rel="external" data-role="button" class="prev hd"><?php echo $form['button']['previous']['value'];?></a>
					<div class="next bd ui-ubtn"><input type="submit" data-theme="f" value="<?php echo
                        $form['button']['submit']['value'];?>" /></div>
				</div>
			</form>
	    	<div id="err-msg"></div>
		</div>
		<?php include('inc/embed_bottom.php');?>
    </body>
</html>
